﻿using System.Collections.Generic;
using System.ComponentModel.DataAnnotations;

namespace viBook.Models
{
    public class ContentTag
    {
        public int Id { get; set; }
        [Required(ErrorMessage = "ContentTagName is required.")]
        [MaxLength(20, ErrorMessage = "ContentTagName cannot be longer than 20 characters.")]
        public string ContentTagName { get; set; }
        [NotMapped]
        public virtual int NumberOfBook { get; set; }
        public virtual IEnumerable<Book> ListBook { set; get; }
    }
}